<html>
<head><title>LMF Salzburger Nachrichten Integration</title></head>
<body>
    <h1>LMF Salzburger Nachrichten Integration</h1>

    <h2>List of Widgets</h2>

    <ul>
        <li><a href="sn/widget/importer.html">Importer Widget</a></li>
    </ul>

    <h2>List of Web Services</h2>
    <h3>/importer/article/application/sn+xml</h3>
    <div style="border:1px solid black;padding:10px;">
        <b>Method: </b>POST<br>
        <b>Url-Parameters: </b>
        <ul>
            <li>url: url of directory; if url is defined, body data is ignored (OPTIONAL)</li>
        </ul>
        <b>Body: </b>file in sn+xml format (OPTIONAL)<br>
        <b>Return: </b>
        <ul>
            <li>HTTP 200 (ok) + JSON: {'tname':'### name of thread ###'}</li>
            <li>HTTP 500 (error)</li>
        </ul>
        <b>Description: </b>Import either a single file (body) or all files of a given directory (urlParam:url) in sn+xml format.
        The import is done asynchronously.
    </div>

    <h3>/sn/importer</h3>
    <div style="border:1px solid black;padding:10px;">
        <b>Method: </b>DELETE<br>
        <b>Url-Parameters:</b>
        <ul>
            <li>tname: name of the tread <b>(MANDATORY)</b></li>
        </ul>
        <b>Body: </b>none<br>
        <b>Return: </b>
        <ul>
            <li>HTTP 200 (ok)</li>
            <li>HTTP 500 (error)</li>
        </ul>
        <b>Description: </b>Stop an import that is running within a thread given by name (urlParam:tname).
    </div>
    <h3>/sn/importer/isActive</h3>
    <div style="border:1px solid black;padding:10px;">
        <b>Method: </b>GET<br>
        <b>Url-Parameters: </b>
        <ul>
            <li>tname: name of the thread (MANDATORY)</li>
        </ul>
        <b>Body: </b>none<br>
        <b>Return: </b>
        <ul>
            <li>HTTP 200 (ok) + JSON: {true} | {false}</li>
            <li>HTTP 500 (error)</li>
        </ul>
        <b>Description: </b>Check if a thread given by name (urlParam:tname) is running at the moment.
    </div>

</body>

</html>
